import sqlite3
import sys
from PyQt5.QtWidgets import QApplication, QWidget
from PyQt5.QtWidgets import QMessageBox
from PyQt5 import QtCore, QtWidgets
import NextOffice.customer.customer_add
import NextOffice.customer.customer_edit


class Ui_Form(object):
    def setupUi(self, Form):
        Form.setObjectName("Form")
        Form.resize(1311, 809)
        self.label_13 = QtWidgets.QLabel(Form)
        self.label_13.setGeometry(QtCore.QRect(540, 10, 161, 31))
        self.label_13.setObjectName("label_13")
        self.label_id1 = QtWidgets.QLabel(Form)
        self.label_id1.setGeometry(QtCore.QRect(120, 60, 91, 21))
        self.label_id1.setObjectName("label_id1")
        self.lineEdit_search = QtWidgets.QLineEdit(Form)
        self.lineEdit_search.setGeometry(QtCore.QRect(160, 10, 113, 20))
        self.lineEdit_search.setObjectName("lineEdit_search")
        self.label_nick1_1 = QtWidgets.QLabel(Form)
        self.label_nick1_1.setGeometry(QtCore.QRect(90, 130, 161, 21))
        self.label_nick1_1.setObjectName("label_nick1_1")
        self.line_7 = QtWidgets.QFrame(Form)
        self.line_7.setGeometry(QtCore.QRect(10, 80, 251, 20))
        self.line_7.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_7.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_7.setObjectName("line_7")
        self.pushButton_SwitchCustomer = QtWidgets.QPushButton(Form)
        self.pushButton_SwitchCustomer.setGeometry(QtCore.QRect(1170, 10, 91, 23))
        self.pushButton_SwitchCustomer.setObjectName("pushButton_SwitchCustomer")
        self.pushButton_edit1 = QtWidgets.QPushButton(Form)
        self.pushButton_edit1.setGeometry(QtCore.QRect(10, 710, 71, 23))
        self.pushButton_edit1.setObjectName("pushButton_edit1")
        self.label_4 = QtWidgets.QLabel(Form)
        self.label_4.setGeometry(QtCore.QRect(30, 148, 41, 41))
        self.label_4.setObjectName("label_4")
        self.line = QtWidgets.QFrame(Form)
        self.line.setGeometry(QtCore.QRect(10, 40, 1291, 20))
        self.line.setFrameShape(QtWidgets.QFrame.HLine)
        self.line.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line.setObjectName("line")
        self.pushButton_SwitchService = QtWidgets.QPushButton(Form)
        self.pushButton_SwitchService.setGeometry(QtCore.QRect(1070, 10, 91, 23))
        self.pushButton_SwitchService.setObjectName("pushButton_SwitchService")
        self.label_8 = QtWidgets.QLabel(Form)
        self.label_8.setGeometry(QtCore.QRect(130, 12, 31, 20))
        self.label_8.setObjectName("label_8")
        self.label_5 = QtWidgets.QLabel(Form)
        self.label_5.setGeometry(QtCore.QRect(30, 180, 31, 39))
        self.label_5.setObjectName("label_5")
        self.label_2 = QtWidgets.QLabel(Form)
        self.label_2.setGeometry(QtCore.QRect(20, 90, 61, 39))
        self.label_2.setObjectName("label_2")
        self.pushButton_previous = QtWidgets.QPushButton(Form)
        self.pushButton_previous.setGeometry(QtCore.QRect(120, 770, 75, 23))
        self.pushButton_previous.setObjectName("pushButton_previous")
        self.pushButton_next = QtWidgets.QPushButton(Form)
        self.pushButton_next.setGeometry(QtCore.QRect(230, 770, 75, 23))
        self.pushButton_next.setObjectName("pushButton_next")
        self.pushButton_new = QtWidgets.QPushButton(Form)
        self.pushButton_new.setGeometry(QtCore.QRect(10, 10, 91, 23))
        self.pushButton_new.setObjectName("pushButton_new")
        self.lineEdit_jump = QtWidgets.QLineEdit(Form)
        self.lineEdit_jump.setGeometry(QtCore.QRect(560, 770, 31, 20))
        self.lineEdit_jump.setObjectName("lineEdit_jump")
        self.pushButton_jump = QtWidgets.QPushButton(Form)
        self.pushButton_jump.setGeometry(QtCore.QRect(620, 770, 41, 21))
        self.pushButton_jump.setObjectName("pushButton_jump")
        self.label_9 = QtWidgets.QLabel(Form)
        self.label_9.setGeometry(QtCore.QRect(520, 760, 91, 39))
        self.label_9.setObjectName("label_9")
        self.label_12 = QtWidgets.QLabel(Form)
        self.label_12.setGeometry(QtCore.QRect(30, 560, 51, 39))
        self.label_12.setObjectName("label_12")
        self.label_14 = QtWidgets.QLabel(Form)
        self.label_14.setGeometry(QtCore.QRect(30, 120, 31, 39))
        self.label_14.setObjectName("label_14")
        self.label_name1 = QtWidgets.QLabel(Form)
        self.label_name1.setGeometry(QtCore.QRect(90, 100, 161, 21))
        self.label_name1.setObjectName("label_name1")
        self.label_nick2_1 = QtWidgets.QLabel(Form)
        self.label_nick2_1.setGeometry(QtCore.QRect(90, 160, 161, 21))
        self.label_nick2_1.setObjectName("label_nick2_1")
        self.label_nick3_1 = QtWidgets.QLabel(Form)
        self.label_nick3_1.setGeometry(QtCore.QRect(90, 190, 151, 21))
        self.label_nick3_1.setObjectName("label_nick3_1")
        self.textBrowser_contact1 = QtWidgets.QTextBrowser(Form)
        self.textBrowser_contact1.setGeometry(QtCore.QRect(90, 230, 161, 321))
        self.textBrowser_contact1.setFrameShadow(QtWidgets.QFrame.Plain)
        self.textBrowser_contact1.setLineWidth(0)
        self.textBrowser_contact1.setObjectName("textBrowser_contact1")
        self.label_21 = QtWidgets.QLabel(Form)
        self.label_21.setGeometry(QtCore.QRect(20, 220, 51, 39))
        self.label_21.setObjectName("label_21")
        self.textBrowser_remark1 = QtWidgets.QTextBrowser(Form)
        self.textBrowser_remark1.setGeometry(QtCore.QRect(90, 560, 161, 131))
        self.textBrowser_remark1.setFrameShadow(QtWidgets.QFrame.Plain)
        self.textBrowser_remark1.setLineWidth(0)
        self.textBrowser_remark1.setObjectName("textBrowser_remark1")
        self.line_8 = QtWidgets.QFrame(Form)
        self.line_8.setGeometry(QtCore.QRect(250, 90, 21, 611))
        self.line_8.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_8.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_8.setObjectName("line_8")
        self.line_9 = QtWidgets.QFrame(Form)
        self.line_9.setGeometry(QtCore.QRect(10, 690, 251, 20))
        self.line_9.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_9.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_9.setObjectName("line_9")
        self.line_10 = QtWidgets.QFrame(Form)
        self.line_10.setGeometry(QtCore.QRect(0, 90, 20, 611))
        self.line_10.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_10.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_10.setObjectName("line_10")
        self.line_11 = QtWidgets.QFrame(Form)
        self.line_11.setGeometry(QtCore.QRect(70, 90, 20, 611))
        self.line_11.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_11.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_11.setObjectName("line_11")
        self.pushButton_search = QtWidgets.QPushButton(Form)
        self.pushButton_search.setGeometry(QtCore.QRect(280, 10, 41, 21))
        self.pushButton_search.setObjectName("pushButton_search")
        self.line_2 = QtWidgets.QFrame(Form)
        self.line_2.setGeometry(QtCore.QRect(10, 740, 1291, 20))
        self.line_2.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_2.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_2.setObjectName("line_2")
        self.pushButton_SwitchShipment = QtWidgets.QPushButton(Form)
        self.pushButton_SwitchShipment.setGeometry(QtCore.QRect(980, 10, 81, 23))
        self.pushButton_SwitchShipment.setObjectName("pushButton_SwitchShipment")
        self.label_22 = QtWidgets.QLabel(Form)
        self.label_22.setGeometry(QtCore.QRect(360, 760, 141, 39))
        self.label_22.setObjectName("label_22")
        self.label_cPage = QtWidgets.QLabel(Form)
        self.label_cPage.setGeometry(QtCore.QRect(390, 770, 31, 21))
        self.label_cPage.setObjectName("label_cPage")
        self.label_tPage = QtWidgets.QLabel(Form)
        self.label_tPage.setGeometry(QtCore.QRect(440, 770, 31, 21))
        self.label_tPage.setObjectName("label_tPage")
        self.line_29 = QtWidgets.QFrame(Form)
        self.line_29.setGeometry(QtCore.QRect(1290, 90, 21, 611))
        self.line_29.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_29.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_29.setObjectName("line_29")
        self.label_order1 = QtWidgets.QLabel(Form)
        self.label_order1.setGeometry(QtCore.QRect(150, 710, 41, 21))
        self.label_order1.setObjectName("label_order1")
        self.label_nick2_2 = QtWidgets.QLabel(Form)
        self.label_nick2_2.setGeometry(QtCore.QRect(350, 160, 161, 21))
        self.label_nick2_2.setObjectName("label_nick2_2")
        self.label_15 = QtWidgets.QLabel(Form)
        self.label_15.setGeometry(QtCore.QRect(290, 560, 51, 39))
        self.label_15.setObjectName("label_15")
        self.line_12 = QtWidgets.QFrame(Form)
        self.line_12.setGeometry(QtCore.QRect(510, 90, 21, 611))
        self.line_12.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_12.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_12.setObjectName("line_12")
        self.textBrowser_contact2 = QtWidgets.QTextBrowser(Form)
        self.textBrowser_contact2.setGeometry(QtCore.QRect(350, 230, 161, 321))
        self.textBrowser_contact2.setFrameShadow(QtWidgets.QFrame.Plain)
        self.textBrowser_contact2.setLineWidth(0)
        self.textBrowser_contact2.setObjectName("textBrowser_contact2")
        self.label_nick3_2 = QtWidgets.QLabel(Form)
        self.label_nick3_2.setGeometry(QtCore.QRect(350, 190, 151, 21))
        self.label_nick3_2.setObjectName("label_nick3_2")
        self.line_13 = QtWidgets.QFrame(Form)
        self.line_13.setGeometry(QtCore.QRect(270, 690, 251, 20))
        self.line_13.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_13.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_13.setObjectName("line_13")
        self.label_name2 = QtWidgets.QLabel(Form)
        self.label_name2.setGeometry(QtCore.QRect(350, 100, 161, 21))
        self.label_name2.setObjectName("label_name2")
        self.label_16 = QtWidgets.QLabel(Form)
        self.label_16.setGeometry(QtCore.QRect(290, 120, 31, 39))
        self.label_16.setObjectName("label_16")
        self.label_6 = QtWidgets.QLabel(Form)
        self.label_6.setGeometry(QtCore.QRect(290, 148, 41, 41))
        self.label_6.setObjectName("label_6")
        self.label_nick1_2 = QtWidgets.QLabel(Form)
        self.label_nick1_2.setGeometry(QtCore.QRect(350, 130, 161, 21))
        self.label_nick1_2.setObjectName("label_nick1_2")
        self.label_7 = QtWidgets.QLabel(Form)
        self.label_7.setGeometry(QtCore.QRect(290, 180, 31, 39))
        self.label_7.setObjectName("label_7")
        self.textBrowser_remark2 = QtWidgets.QTextBrowser(Form)
        self.textBrowser_remark2.setGeometry(QtCore.QRect(350, 560, 161, 131))
        self.textBrowser_remark2.setFrameShadow(QtWidgets.QFrame.Plain)
        self.textBrowser_remark2.setLineWidth(0)
        self.textBrowser_remark2.setObjectName("textBrowser_remark2")
        self.label_3 = QtWidgets.QLabel(Form)
        self.label_3.setGeometry(QtCore.QRect(280, 90, 61, 39))
        self.label_3.setObjectName("label_3")
        self.line_14 = QtWidgets.QFrame(Form)
        self.line_14.setGeometry(QtCore.QRect(270, 80, 251, 20))
        self.line_14.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_14.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_14.setObjectName("line_14")
        self.label_order2 = QtWidgets.QLabel(Form)
        self.label_order2.setGeometry(QtCore.QRect(410, 710, 41, 21))
        self.label_order2.setObjectName("label_order2")
        self.line_15 = QtWidgets.QFrame(Form)
        self.line_15.setGeometry(QtCore.QRect(260, 90, 20, 611))
        self.line_15.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_15.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_15.setObjectName("line_15")
        self.pushButton_edit2 = QtWidgets.QPushButton(Form)
        self.pushButton_edit2.setGeometry(QtCore.QRect(270, 710, 71, 23))
        self.pushButton_edit2.setObjectName("pushButton_edit2")
        self.label_id2 = QtWidgets.QLabel(Form)
        self.label_id2.setGeometry(QtCore.QRect(380, 60, 91, 21))
        self.label_id2.setObjectName("label_id2")
        self.label_23 = QtWidgets.QLabel(Form)
        self.label_23.setGeometry(QtCore.QRect(280, 220, 51, 39))
        self.label_23.setObjectName("label_23")
        self.line_16 = QtWidgets.QFrame(Form)
        self.line_16.setGeometry(QtCore.QRect(330, 90, 20, 611))
        self.line_16.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_16.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_16.setObjectName("line_16")
        self.label_nick2_3 = QtWidgets.QLabel(Form)
        self.label_nick2_3.setGeometry(QtCore.QRect(610, 160, 161, 21))
        self.label_nick2_3.setObjectName("label_nick2_3")
        self.label_17 = QtWidgets.QLabel(Form)
        self.label_17.setGeometry(QtCore.QRect(550, 560, 51, 39))
        self.label_17.setObjectName("label_17")
        self.line_17 = QtWidgets.QFrame(Form)
        self.line_17.setGeometry(QtCore.QRect(770, 90, 21, 611))
        self.line_17.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_17.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_17.setObjectName("line_17")
        self.textBrowser_contact3 = QtWidgets.QTextBrowser(Form)
        self.textBrowser_contact3.setGeometry(QtCore.QRect(610, 230, 161, 321))
        self.textBrowser_contact3.setFrameShadow(QtWidgets.QFrame.Plain)
        self.textBrowser_contact3.setLineWidth(0)
        self.textBrowser_contact3.setObjectName("textBrowser_contact3")
        self.label_nick3_3 = QtWidgets.QLabel(Form)
        self.label_nick3_3.setGeometry(QtCore.QRect(610, 190, 151, 21))
        self.label_nick3_3.setObjectName("label_nick3_3")
        self.line_18 = QtWidgets.QFrame(Form)
        self.line_18.setGeometry(QtCore.QRect(530, 690, 251, 20))
        self.line_18.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_18.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_18.setObjectName("line_18")
        self.label_name3 = QtWidgets.QLabel(Form)
        self.label_name3.setGeometry(QtCore.QRect(610, 100, 161, 21))
        self.label_name3.setObjectName("label_name3")
        self.label_18 = QtWidgets.QLabel(Form)
        self.label_18.setGeometry(QtCore.QRect(550, 120, 31, 39))
        self.label_18.setObjectName("label_18")
        self.label_10 = QtWidgets.QLabel(Form)
        self.label_10.setGeometry(QtCore.QRect(550, 148, 41, 41))
        self.label_10.setObjectName("label_10")
        self.label_nick1_3 = QtWidgets.QLabel(Form)
        self.label_nick1_3.setGeometry(QtCore.QRect(610, 130, 161, 21))
        self.label_nick1_3.setObjectName("label_nick1_3")
        self.label_11 = QtWidgets.QLabel(Form)
        self.label_11.setGeometry(QtCore.QRect(550, 180, 31, 39))
        self.label_11.setObjectName("label_11")
        self.textBrowser_remark3 = QtWidgets.QTextBrowser(Form)
        self.textBrowser_remark3.setGeometry(QtCore.QRect(610, 560, 161, 131))
        self.textBrowser_remark3.setFrameShadow(QtWidgets.QFrame.Plain)
        self.textBrowser_remark3.setLineWidth(0)
        self.textBrowser_remark3.setObjectName("textBrowser_remark3")
        self.label_19 = QtWidgets.QLabel(Form)
        self.label_19.setGeometry(QtCore.QRect(540, 90, 61, 39))
        self.label_19.setObjectName("label_19")
        self.line_19 = QtWidgets.QFrame(Form)
        self.line_19.setGeometry(QtCore.QRect(530, 80, 251, 20))
        self.line_19.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_19.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_19.setObjectName("line_19")
        self.label_order3 = QtWidgets.QLabel(Form)
        self.label_order3.setGeometry(QtCore.QRect(670, 710, 41, 21))
        self.label_order3.setObjectName("label_order3")
        self.line_20 = QtWidgets.QFrame(Form)
        self.line_20.setGeometry(QtCore.QRect(520, 90, 20, 611))
        self.line_20.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_20.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_20.setObjectName("line_20")
        self.pushButton_edit3 = QtWidgets.QPushButton(Form)
        self.pushButton_edit3.setGeometry(QtCore.QRect(530, 710, 71, 23))
        self.pushButton_edit3.setObjectName("pushButton_edit3")
        self.label_id3 = QtWidgets.QLabel(Form)
        self.label_id3.setGeometry(QtCore.QRect(640, 60, 91, 21))
        self.label_id3.setObjectName("label_id3")
        self.label_24 = QtWidgets.QLabel(Form)
        self.label_24.setGeometry(QtCore.QRect(540, 220, 51, 39))
        self.label_24.setObjectName("label_24")
        self.line_21 = QtWidgets.QFrame(Form)
        self.line_21.setGeometry(QtCore.QRect(590, 90, 20, 611))
        self.line_21.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_21.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_21.setObjectName("line_21")
        self.label_nick2_4 = QtWidgets.QLabel(Form)
        self.label_nick2_4.setGeometry(QtCore.QRect(870, 160, 161, 21))
        self.label_nick2_4.setObjectName("label_nick2_4")
        self.label_20 = QtWidgets.QLabel(Form)
        self.label_20.setGeometry(QtCore.QRect(810, 560, 51, 39))
        self.label_20.setObjectName("label_20")
        self.line_22 = QtWidgets.QFrame(Form)
        self.line_22.setGeometry(QtCore.QRect(1030, 90, 21, 611))
        self.line_22.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_22.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_22.setObjectName("line_22")
        self.textBrowser_contact4 = QtWidgets.QTextBrowser(Form)
        self.textBrowser_contact4.setGeometry(QtCore.QRect(870, 230, 161, 321))
        self.textBrowser_contact4.setFrameShadow(QtWidgets.QFrame.Plain)
        self.textBrowser_contact4.setLineWidth(0)
        self.textBrowser_contact4.setObjectName("textBrowser_contact4")
        self.label_nick3_4 = QtWidgets.QLabel(Form)
        self.label_nick3_4.setGeometry(QtCore.QRect(870, 190, 151, 21))
        self.label_nick3_4.setObjectName("label_nick3_4")
        self.line_23 = QtWidgets.QFrame(Form)
        self.line_23.setGeometry(QtCore.QRect(790, 690, 251, 20))
        self.line_23.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_23.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_23.setObjectName("line_23")
        self.label_name4 = QtWidgets.QLabel(Form)
        self.label_name4.setGeometry(QtCore.QRect(870, 100, 161, 21))
        self.label_name4.setObjectName("label_name4")
        self.label_25 = QtWidgets.QLabel(Form)
        self.label_25.setGeometry(QtCore.QRect(810, 120, 31, 39))
        self.label_25.setObjectName("label_25")
        self.label_26 = QtWidgets.QLabel(Form)
        self.label_26.setGeometry(QtCore.QRect(810, 148, 41, 41))
        self.label_26.setObjectName("label_26")
        self.label_nick1_4 = QtWidgets.QLabel(Form)
        self.label_nick1_4.setGeometry(QtCore.QRect(870, 130, 161, 21))
        self.label_nick1_4.setObjectName("label_nick1_4")
        self.label_27 = QtWidgets.QLabel(Form)
        self.label_27.setGeometry(QtCore.QRect(810, 180, 31, 39))
        self.label_27.setObjectName("label_27")
        self.textBrowser_remark4 = QtWidgets.QTextBrowser(Form)
        self.textBrowser_remark4.setGeometry(QtCore.QRect(870, 560, 161, 131))
        self.textBrowser_remark4.setFrameShadow(QtWidgets.QFrame.Plain)
        self.textBrowser_remark4.setLineWidth(0)
        self.textBrowser_remark4.setObjectName("textBrowser_remark4")
        self.label_28 = QtWidgets.QLabel(Form)
        self.label_28.setGeometry(QtCore.QRect(800, 90, 61, 39))
        self.label_28.setObjectName("label_28")
        self.line_24 = QtWidgets.QFrame(Form)
        self.line_24.setGeometry(QtCore.QRect(790, 80, 251, 20))
        self.line_24.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_24.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_24.setObjectName("line_24")
        self.label_order4 = QtWidgets.QLabel(Form)
        self.label_order4.setGeometry(QtCore.QRect(930, 710, 41, 21))
        self.label_order4.setObjectName("label_order4")
        self.line_25 = QtWidgets.QFrame(Form)
        self.line_25.setGeometry(QtCore.QRect(780, 90, 20, 611))
        self.line_25.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_25.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_25.setObjectName("line_25")
        self.pushButton_edit4 = QtWidgets.QPushButton(Form)
        self.pushButton_edit4.setGeometry(QtCore.QRect(790, 710, 71, 23))
        self.pushButton_edit4.setObjectName("pushButton_edit4")
        self.label_id4 = QtWidgets.QLabel(Form)
        self.label_id4.setGeometry(QtCore.QRect(900, 60, 91, 21))
        self.label_id4.setObjectName("label_id4")
        self.label_29 = QtWidgets.QLabel(Form)
        self.label_29.setGeometry(QtCore.QRect(800, 220, 51, 39))
        self.label_29.setObjectName("label_29")
        self.line_26 = QtWidgets.QFrame(Form)
        self.line_26.setGeometry(QtCore.QRect(850, 90, 20, 611))
        self.line_26.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_26.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_26.setObjectName("line_26")
        self.label_nick2_5 = QtWidgets.QLabel(Form)
        self.label_nick2_5.setGeometry(QtCore.QRect(1130, 160, 161, 21))
        self.label_nick2_5.setObjectName("label_nick2_5")
        self.label_30 = QtWidgets.QLabel(Form)
        self.label_30.setGeometry(QtCore.QRect(1070, 560, 51, 39))
        self.label_30.setObjectName("label_30")
        self.line_27 = QtWidgets.QFrame(Form)
        self.line_27.setGeometry(QtCore.QRect(1290, 90, 21, 611))
        self.line_27.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_27.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_27.setObjectName("line_27")
        self.textBrowser_contact5 = QtWidgets.QTextBrowser(Form)
        self.textBrowser_contact5.setGeometry(QtCore.QRect(1130, 230, 161, 321))
        self.textBrowser_contact5.setFrameShadow(QtWidgets.QFrame.Plain)
        self.textBrowser_contact5.setLineWidth(0)
        self.textBrowser_contact5.setObjectName("textBrowser_contact5")
        self.label_nick3_5 = QtWidgets.QLabel(Form)
        self.label_nick3_5.setGeometry(QtCore.QRect(1130, 190, 151, 21))
        self.label_nick3_5.setObjectName("label_nick3_5")
        self.line_28 = QtWidgets.QFrame(Form)
        self.line_28.setGeometry(QtCore.QRect(1050, 690, 251, 20))
        self.line_28.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_28.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_28.setObjectName("line_28")
        self.label_name5 = QtWidgets.QLabel(Form)
        self.label_name5.setGeometry(QtCore.QRect(1130, 100, 161, 21))
        self.label_name5.setObjectName("label_name5")
        self.label_31 = QtWidgets.QLabel(Form)
        self.label_31.setGeometry(QtCore.QRect(1070, 120, 31, 39))
        self.label_31.setObjectName("label_31")
        self.label_32 = QtWidgets.QLabel(Form)
        self.label_32.setGeometry(QtCore.QRect(1070, 148, 41, 41))
        self.label_32.setObjectName("label_32")
        self.label_nick1_5 = QtWidgets.QLabel(Form)
        self.label_nick1_5.setGeometry(QtCore.QRect(1130, 130, 161, 21))
        self.label_nick1_5.setObjectName("label_nick1_5")
        self.label_33 = QtWidgets.QLabel(Form)
        self.label_33.setGeometry(QtCore.QRect(1070, 180, 31, 39))
        self.label_33.setObjectName("label_33")
        self.textBrowser_remark5 = QtWidgets.QTextBrowser(Form)
        self.textBrowser_remark5.setGeometry(QtCore.QRect(1130, 560, 161, 131))
        self.textBrowser_remark5.setFrameShadow(QtWidgets.QFrame.Plain)
        self.textBrowser_remark5.setLineWidth(0)
        self.textBrowser_remark5.setObjectName("textBrowser_remark5")
        self.label_34 = QtWidgets.QLabel(Form)
        self.label_34.setGeometry(QtCore.QRect(1060, 90, 61, 39))
        self.label_34.setObjectName("label_34")
        self.line_30 = QtWidgets.QFrame(Form)
        self.line_30.setGeometry(QtCore.QRect(1050, 80, 251, 20))
        self.line_30.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_30.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_30.setObjectName("line_30")
        self.label_order5 = QtWidgets.QLabel(Form)
        self.label_order5.setGeometry(QtCore.QRect(1190, 710, 41, 21))
        self.label_order5.setObjectName("label_order5")
        self.line_31 = QtWidgets.QFrame(Form)
        self.line_31.setGeometry(QtCore.QRect(1040, 90, 20, 611))
        self.line_31.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_31.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_31.setObjectName("line_31")
        self.pushButton_edit5 = QtWidgets.QPushButton(Form)
        self.pushButton_edit5.setGeometry(QtCore.QRect(1050, 710, 71, 23))
        self.pushButton_edit5.setObjectName("pushButton_edit5")
        self.label_id5 = QtWidgets.QLabel(Form)
        self.label_id5.setGeometry(QtCore.QRect(1160, 60, 91, 21))
        self.label_id5.setObjectName("label_id5")
        self.label_35 = QtWidgets.QLabel(Form)
        self.label_35.setGeometry(QtCore.QRect(1060, 220, 51, 39))
        self.label_35.setObjectName("label_35")
        self.line_32 = QtWidgets.QFrame(Form)
        self.line_32.setGeometry(QtCore.QRect(1110, 90, 20, 611))
        self.line_32.setFrameShape(QtWidgets.QFrame.VLine)
        self.line_32.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_32.setObjectName("line_32")
        self.label_13.raise_()
        self.label_id1.raise_()
        self.lineEdit_search.raise_()
        self.label_nick1_1.raise_()
        self.line_7.raise_()
        self.pushButton_SwitchCustomer.raise_()
        self.pushButton_edit1.raise_()
        self.label_4.raise_()
        self.line.raise_()
        self.pushButton_SwitchService.raise_()
        self.label_8.raise_()
        self.label_5.raise_()
        self.label_2.raise_()
        self.pushButton_previous.raise_()
        self.pushButton_next.raise_()
        self.pushButton_new.raise_()
        self.pushButton_jump.raise_()
        self.label_9.raise_()
        self.lineEdit_jump.raise_()
        self.label_12.raise_()
        self.label_14.raise_()
        self.label_name1.raise_()
        self.label_nick2_1.raise_()
        self.label_nick3_1.raise_()
        self.textBrowser_contact1.raise_()
        self.label_21.raise_()
        self.textBrowser_remark1.raise_()
        self.line_8.raise_()
        self.line_9.raise_()
        self.line_10.raise_()
        self.line_11.raise_()
        self.pushButton_search.raise_()
        self.line_2.raise_()
        self.pushButton_SwitchShipment.raise_()
        self.label_22.raise_()
        self.label_cPage.raise_()
        self.label_tPage.raise_()
        self.line_29.raise_()
        self.label_order1.raise_()
        self.label_nick2_2.raise_()
        self.label_15.raise_()
        self.line_12.raise_()
        self.textBrowser_contact2.raise_()
        self.label_nick3_2.raise_()
        self.line_13.raise_()
        self.label_name2.raise_()
        self.label_16.raise_()
        self.label_6.raise_()
        self.label_nick1_2.raise_()
        self.label_7.raise_()
        self.textBrowser_remark2.raise_()
        self.label_3.raise_()
        self.line_14.raise_()
        self.label_order2.raise_()
        self.line_15.raise_()
        self.pushButton_edit2.raise_()
        self.label_id2.raise_()
        self.label_23.raise_()
        self.line_16.raise_()
        self.label_nick2_3.raise_()
        self.label_17.raise_()
        self.line_17.raise_()
        self.textBrowser_contact3.raise_()
        self.label_nick3_3.raise_()
        self.line_18.raise_()
        self.label_name3.raise_()
        self.label_18.raise_()
        self.label_10.raise_()
        self.label_nick1_3.raise_()
        self.label_11.raise_()
        self.textBrowser_remark3.raise_()
        self.label_19.raise_()
        self.line_19.raise_()
        self.label_order3.raise_()
        self.line_20.raise_()
        self.pushButton_edit3.raise_()
        self.label_id3.raise_()
        self.label_24.raise_()
        self.line_21.raise_()
        self.label_nick2_4.raise_()
        self.label_20.raise_()
        self.line_22.raise_()
        self.textBrowser_contact4.raise_()
        self.label_nick3_4.raise_()
        self.line_23.raise_()
        self.label_name4.raise_()
        self.label_25.raise_()
        self.label_26.raise_()
        self.label_nick1_4.raise_()
        self.label_27.raise_()
        self.textBrowser_remark4.raise_()
        self.label_28.raise_()
        self.line_24.raise_()
        self.label_order4.raise_()
        self.line_25.raise_()
        self.pushButton_edit4.raise_()
        self.label_id4.raise_()
        self.label_29.raise_()
        self.line_26.raise_()
        self.label_nick2_5.raise_()
        self.label_30.raise_()
        self.line_27.raise_()
        self.textBrowser_contact5.raise_()
        self.label_nick3_5.raise_()
        self.line_28.raise_()
        self.label_name5.raise_()
        self.label_31.raise_()
        self.label_32.raise_()
        self.label_nick1_5.raise_()
        self.label_33.raise_()
        self.textBrowser_remark5.raise_()
        self.label_34.raise_()
        self.line_30.raise_()
        self.label_order5.raise_()
        self.line_31.raise_()
        self.pushButton_edit5.raise_()
        self.label_id5.raise_()
        self.label_35.raise_()
        self.line_32.raise_()

        self.retranslateUi(Form)
        self.pushButton_previous.clicked.connect(self.reloadWidgetDec)
        self.pushButton_next.clicked.connect(self.reloadWidgetAdd)
        QtCore.QMetaObject.connectSlotsByName(Form)
    def retranslateUi(self, Form):
        _translate = QtCore.QCoreApplication.translate
        Form.setWindowTitle(_translate("Form", "Form"))
        self.label_13.setText(_translate("Form", "<html><head/><body><p align=\"center\"><span style=\" font-size:16pt; font-weight:600; color:#0b3da8;\">客户信息浏览</span></p></body></html>"))
        self.label_id1.setText(_translate("Form", "customerID"))
        self.label_nick1_1.setText(_translate("Form", "<html><head/><body><p><span style=\" font-size:10pt; font-weight:600; color:#063661;\">customer</span></p></body></html>"))
        self.pushButton_SwitchCustomer.setText(_translate("Form", "客户信息界面"))
        self.pushButton_edit1.setText(_translate("Form", "编辑"))
        self.label_4.setText(_translate("Form", "别称2"))
        self.pushButton_SwitchService.setText(_translate("Form", "售后服务记录"))
        self.label_8.setText(_translate("Form", "搜索"))
        self.label_5.setText(_translate("Form", "别称3"))
        self.label_2.setText(_translate("Form", "客户名称"))
        self.pushButton_previous.setText(_translate("Form", "上一页"))
        self.pushButton_next.setText(_translate("Form", "下一页"))
        self.pushButton_new.setText(_translate("Form", "新增客户信息"))
        self.pushButton_jump.setText(_translate("Form", "GO!"))
        self.label_9.setText(_translate("Form", "跳到第       页"))
        self.label_12.setText(_translate("Form", "备注"))
        self.label_14.setText(_translate("Form", "别称1"))
        self.label_name1.setText(_translate("Form", "name"))
        self.label_nick2_1.setText(_translate("Form", "<html><head/><body><p><span style=\" font-size:10pt; font-weight:600; color:#063661;\">production</span></p></body></html>"))
        self.label_nick3_1.setText(_translate("Form", "model"))
        self.textBrowser_contact1.setHtml(_translate("Form", "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n"
"<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n"
"p, li { white-space: pre-wrap; }\n"
"</style></head><body style=\" font-family:\'SimSun\'; font-size:9pt; font-weight:400; font-style:normal;\">\n"
"<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\">shipto</p></body></html>"))
        self.label_21.setText(_translate("Form", "联系方式"))
        self.textBrowser_remark1.setHtml(_translate("Form", "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n"
"<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n"
"p, li { white-space: pre-wrap; }\n"
"</style></head><body style=\" font-family:\'SimSun\'; font-size:9pt; font-weight:400; font-style:normal;\">\n"
"<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\">remark</p></body></html>"))
        self.pushButton_search.setText(_translate("Form", "GO!"))
        self.pushButton_SwitchShipment.setText(_translate("Form", "产品出货信息"))
        self.label_22.setText(_translate("Form", "第        /         页"))
        self.label_cPage.setText(_translate("Form", "<html><head/><body><p><span style=\" font-size:10pt; color:#063661;\">cPage</span></p></body></html>"))
        self.label_tPage.setText(_translate("Form", "<html><head/><body><p><span style=\" font-size:10pt; color:#063661;\">tPage</span></p></body></html>"))
        self.label_order1.setText(_translate("Form", "order"))
        self.label_nick2_2.setText(_translate("Form", "<html><head/><body><p><span style=\" font-size:10pt; font-weight:600; color:#063661;\">production</span></p></body></html>"))
        self.label_15.setText(_translate("Form", "备注"))
        self.textBrowser_contact2.setHtml(_translate("Form", "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n"
"<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n"
"p, li { white-space: pre-wrap; }\n"
"</style></head><body style=\" font-family:\'SimSun\'; font-size:9pt; font-weight:400; font-style:normal;\">\n"
"<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\">shipto</p></body></html>"))
        self.label_nick3_2.setText(_translate("Form", "model"))
        self.label_name2.setText(_translate("Form", "name"))
        self.label_16.setText(_translate("Form", "别称1"))
        self.label_6.setText(_translate("Form", "别称2"))
        self.label_nick1_2.setText(_translate("Form", "<html><head/><body><p><span style=\" font-size:10pt; font-weight:600; color:#063661;\">customer</span></p></body></html>"))
        self.label_7.setText(_translate("Form", "别称3"))
        self.textBrowser_remark2.setHtml(_translate("Form", "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n"
"<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n"
"p, li { white-space: pre-wrap; }\n"
"</style></head><body style=\" font-family:\'SimSun\'; font-size:9pt; font-weight:400; font-style:normal;\">\n"
"<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\">remark</p></body></html>"))
        self.label_3.setText(_translate("Form", "客户名称"))
        self.label_order2.setText(_translate("Form", "order"))
        self.pushButton_edit2.setText(_translate("Form", "编辑"))
        self.label_id2.setText(_translate("Form", "customerID"))
        self.label_23.setText(_translate("Form", "联系方式"))
        self.label_nick2_3.setText(_translate("Form", "<html><head/><body><p><span style=\" font-size:10pt; font-weight:600; color:#063661;\">production</span></p></body></html>"))
        self.label_17.setText(_translate("Form", "备注"))
        self.textBrowser_contact3.setHtml(_translate("Form", "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n"
"<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n"
"p, li { white-space: pre-wrap; }\n"
"</style></head><body style=\" font-family:\'SimSun\'; font-size:9pt; font-weight:400; font-style:normal;\">\n"
"<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\">shipto</p></body></html>"))
        self.label_nick3_3.setText(_translate("Form", "model"))
        self.label_name3.setText(_translate("Form", "name"))
        self.label_18.setText(_translate("Form", "别称1"))
        self.label_10.setText(_translate("Form", "别称2"))
        self.label_nick1_3.setText(_translate("Form", "<html><head/><body><p><span style=\" font-size:10pt; font-weight:600; color:#063661;\">customer</span></p></body></html>"))
        self.label_11.setText(_translate("Form", "别称3"))
        self.textBrowser_remark3.setHtml(_translate("Form", "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n"
"<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n"
"p, li { white-space: pre-wrap; }\n"
"</style></head><body style=\" font-family:\'SimSun\'; font-size:9pt; font-weight:400; font-style:normal;\">\n"
"<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\">remark</p></body></html>"))
        self.label_19.setText(_translate("Form", "客户名称"))
        self.label_order3.setText(_translate("Form", "order"))
        self.pushButton_edit3.setText(_translate("Form", "编辑"))
        self.label_id3.setText(_translate("Form", "customerID"))
        self.label_24.setText(_translate("Form", "联系方式"))
        self.label_nick2_4.setText(_translate("Form", "<html><head/><body><p><span style=\" font-size:10pt; font-weight:600; color:#063661;\">production</span></p></body></html>"))
        self.label_20.setText(_translate("Form", "备注"))
        self.textBrowser_contact4.setHtml(_translate("Form", "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n"
"<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n"
"p, li { white-space: pre-wrap; }\n"
"</style></head><body style=\" font-family:\'SimSun\'; font-size:9pt; font-weight:400; font-style:normal;\">\n"
"<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\">shipto</p></body></html>"))
        self.label_nick3_4.setText(_translate("Form", "model"))
        self.label_name4.setText(_translate("Form", "name"))
        self.label_25.setText(_translate("Form", "别称1"))
        self.label_26.setText(_translate("Form", "别称2"))
        self.label_nick1_4.setText(_translate("Form", "<html><head/><body><p><span style=\" font-size:10pt; font-weight:600; color:#063661;\">customer</span></p></body></html>"))
        self.label_27.setText(_translate("Form", "别称3"))
        self.textBrowser_remark4.setHtml(_translate("Form", "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n"
"<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n"
"p, li { white-space: pre-wrap; }\n"
"</style></head><body style=\" font-family:\'SimSun\'; font-size:9pt; font-weight:400; font-style:normal;\">\n"
"<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\">remark</p></body></html>"))
        self.label_28.setText(_translate("Form", "客户名称"))
        self.label_order4.setText(_translate("Form", "order"))
        self.pushButton_edit4.setText(_translate("Form", "编辑"))
        self.label_id4.setText(_translate("Form", "customerID"))
        self.label_29.setText(_translate("Form", "联系方式"))
        self.label_nick2_5.setText(_translate("Form", "<html><head/><body><p><span style=\" font-size:10pt; font-weight:600; color:#063661;\">production</span></p></body></html>"))
        self.label_30.setText(_translate("Form", "备注"))
        self.textBrowser_contact5.setHtml(_translate("Form", "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n"
"<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n"
"p, li { white-space: pre-wrap; }\n"
"</style></head><body style=\" font-family:\'SimSun\'; font-size:9pt; font-weight:400; font-style:normal;\">\n"
"<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\">shipto</p></body></html>"))
        self.label_nick3_5.setText(_translate("Form", "model"))
        self.label_name5.setText(_translate("Form", "name"))
        self.label_31.setText(_translate("Form", "别称1"))
        self.label_32.setText(_translate("Form", "别称2"))
        self.label_nick1_5.setText(_translate("Form", "<html><head/><body><p><span style=\" font-size:10pt; font-weight:600; color:#063661;\">customer</span></p></body></html>"))
        self.label_33.setText(_translate("Form", "别称3"))
        self.textBrowser_remark5.setHtml(_translate("Form", "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n"
"<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n"
"p, li { white-space: pre-wrap; }\n"
"</style></head><body style=\" font-family:\'SimSun\'; font-size:9pt; font-weight:400; font-style:normal;\">\n"
"<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\">remark</p></body></html>"))
        self.label_34.setText(_translate("Form", "客户名称"))
        self.label_order5.setText(_translate("Form", "order"))
        self.pushButton_edit5.setText(_translate("Form", "编辑"))
        self.label_id5.setText(_translate("Form", "customerID"))
        self.label_35.setText(_translate("Form", "联系方式"))

####以上为QTDesiger自动生成代码
###以下为自己写的代码
    def closeEvent(self, event):        #关闭窗口触发以下事件
        reply = QMessageBox.question(self, '消息提示', '你确定要退出吗?', QMessageBox.Yes | QMessageBox.No, QMessageBox.No)
        if reply == QMessageBox.Yes:
            event.accept()        #接受关闭事件
        else:
            event.ignore()        #忽略关闭事件

    def reloadWidgetAdd(self,i): #点击下一页触发
        print ("reloadWidgeAdd")
        i= int(self.label_order5.text())
        if i < self.dblen():
#            global g
            NextOffice.customer.customer_main.g=NextOffice.customer.customer_main.g+1 #全局变量P页数+1
            self.pageDisplay(NextOffice.customer.customer_main.g)
            print("customer_main的g是",NextOffice.customer.customer_main.g)

        else:
            print("remain")
    def reloadWidgetDec(self,i): #点击上一页触发
        print ("reloadWidgeDec")
        i= int(self.label_order5.text())
        if i > 5:
            global g
            NextOffice.customer.customer_main.g=NextOffice.customer.customer_main.g-1 #全局变量P页数+1
#            g=g-1 #全局变量P页数-1
            self.pageDisplay(NextOffice.customer.customer_main.g)
        else:
            print("remain")
    def pageDisplay(self,g):  #本函数显示g页的数据

        self.pushButton_edit2.show() #显示开始，先把之前可能隐藏的按钮重新显示出来
        self.pushButton_edit3.show()
        self.pushButton_edit4.show()
        self.pushButton_edit5.show()
        self.pushButton_edit6.show()
        self.pushButton_edit7.show()
        self.pushButton_edit8.show()
        self.pushButton_edit9.show()
        self.pushButton_edit10.show()

        self.pushButton_detail2.show()#显示开始，先把之前可能隐藏的按钮重新显示出来
        self.pushButton_detail3.show()
        self.pushButton_detail4.show()
        self.pushButton_detail5.show()
        self.pushButton_detail6.show()
        self.pushButton_detail7.show()
        self.pushButton_detail8.show()
        self.pushButton_detail9.show()
        self.pushButton_detail10.show()


        print("shipment_browser: pageDisplay",g)
        orderJ=g*10
        orderI=orderJ-1
        orderH=orderJ-2
        orderG=orderJ-3
        orderF=orderJ-4
        orderE=orderJ-5
        orderD=orderJ-6
        orderC=orderJ-7
        orderB=orderJ-8
        orderA=orderJ-9
        self.label_order1.setText(str(orderA))
        self.label_order2.setText(str(orderB))
        self.label_order3.setText(str(orderC))
        self.label_order4.setText(str(orderD))
        self.label_order5.setText(str(orderE))
        self.label_order6.setText(str(orderF))
        self.label_order7.setText(str(orderG))
        self.label_order8.setText(str(orderH))
        self.label_order9.setText(str(orderI))
        self.label_order10.setText(str(orderJ))


        conn = sqlite3.connect('nextai.db')
        curs = conn.cursor()  #创建游标
        curs.execute("SELECT * from customer")
        data= curs.fetchall() #将数据库全部内容读入data中
        curs.close()  #关闭游标
        conn.commit() #保存数据库
        conn.close() #关闭数据库连接

        p=g*5-4  #获得当前页面的第1行

        blank=["","","","","","",""]
        dblen=self.dblen()
        print("customer_browser-pageDisplay:现在数据库中共有记录：",dblen)
        a=dblen%5 #计算最后一页总共有几行？
        b=5-a  #计算空白的有几行
        while b>0:#将当前页面的空白记录行填充N/A，以免data赋值的时候不够5行导致出错
            data.append(blank)
            if g == dblen//5+1:  #如果当前页面是最后一页---总页数/5然后+1
                if b==1: #如果只有1行空白
                    self.pushButton_edit5.hide() #隐藏最后一个编辑按钮
                elif b==2:#如果有2行空白
                    self.pushButton_edit4.hide() #隐藏最后2个编辑按钮
                    self.pushButton_edit5.hide()
                elif b==3:#如果有3行空白
                    self.pushButton_edit3.hide() #隐藏最后2个编辑按钮
                    self.pushButton_edit4.hide() #隐藏最后2个编辑按钮
                    self.pushButton_edit5.hide()
                elif b==4:#如果有4行空白
                    self.pushButton_edit2.hide() #隐藏最后2个编辑按钮
                    self.pushButton_edit3.hide() #隐藏最后2个编辑按钮
                    self.pushButton_edit4.hide() #隐藏最后2个编辑按钮
                    self.pushButton_edit5.hide()
            b=b-1

#以下将数据库中获取的内容分别对应显示在5行内
        self.label_id1.setText(str(data[p-1][0])) #数据库是从0开始的，所以减1
        self.label_name1.setText(str(data[p-1][1]))
        self.label_nick1_1.setText(str(data[p-1][2]))
        self.label_nick2_1.setText(str(data[p-1][3]))
        self.label_nick3_1.setText(str(data[p-1][4]))
        self.textBrowser_contact1.setText(str(data[p-1][5]))
        self.textBrowser_remark1.setText(str(data[p-1][6]))

        self.label_id2.setText(str(data[p][0]))
        self.label_name2.setText(str(data[p][1]))
        self.label_nick1_2.setText(str(data[p][2]))
        self.label_nick2_2.setText(str(data[p][3]))
        self.label_nick3_2.setText(str(data[p][4]))
        self.textBrowser_contact2.setText(str(data[p][5]))
        self.textBrowser_remark2.setText(str(data[p][6]))

        self.label_id3.setText(str(data[p+1][0]))
        self.label_name3.setText(str(data[p+1][1]))
        self.label_nick1_3.setText(str(data[p+1][2]))
        self.label_nick2_3.setText(str(data[p+1][3]))
        self.label_nick3_3.setText(str(data[p+1][4]))
        self.textBrowser_contact3.setText(str(data[p+1][5]))
        self.textBrowser_remark3.setText(str(data[p+1][6]))

        self.label_id4.setText(str(data[p+2][0]))
        self.label_name4.setText(str(data[p+2][1]))
        self.label_nick1_4.setText(str(data[p+2][2]))
        self.label_nick2_4.setText(str(data[p+2][3]))
        self.label_nick3_4.setText(str(data[p+2][4]))
        self.textBrowser_contact4.setText(str(data[p+2][5]))
        self.textBrowser_remark4.setText(str(data[p+2][6]))

        self.label_id5.setText(str(data[p+3][0]))
        self.label_name5.setText(str(data[p+3][1]))
        self.label_nick1_5.setText(str(data[p+3][2]))
        self.label_nick2_5.setText(str(data[p+3][3]))
        self.label_nick3_5.setText(str(data[p+3][4]))
        self.textBrowser_contact5.setText(str(data[p+3][5]))
        self.textBrowser_remark5.setText(str(data[p+3][6]))
# 以下设置页面中的当前页/总页数
        self.label_cPage.setText(str(g))
        if dblen%5==0: #如果能被5整除，就说明总记录刚好是5的倍数
            tPage=int(dblen/5)
        else:
            tPage=int(dblen/5+1) #否则，就应该加1页
        self.label_tPage.setText(str(tPage))

    def page(self):
        global g
        g=g+0
        return g
    def reload(self):
        print("browser:reload start")
        print("g=",NextOffice.customer.customer_main.g)
        print("???")
        self.pageDisplay(NextOffice.customer.customer_main.g)
        print("browser:reload finish")
    def dblen(self):
        conn = sqlite3.connect('nextai.db')
        curs = conn.cursor()  #创建游标
#        print ("打开数据库成功")

        curs.execute("SELECT * from customer")
        data= curs.fetchall()
#        print (data[10])
#        print (data[0][0])
#        print (data[0][1])

        lens=len(data)
        print ("数据库共有记录：",lens)


        curs.close()  #关闭游标
        conn.commit() #保存数据库
        conn.close() #关闭数据库连接
        return lens
    def jumpTo(self):

        jump_g=str(self.lineEdit_jump.text())
        print("jump start")
        if jump_g=="":
            QMessageBox.critical(self,"注意","输入错误，请输入要跳转到的页码，格式为数字")
            pass
        elif jump_g.isdigit()==False:
            QMessageBox.critical(self,"注意","输入错误，请输入要跳转到的页码，格式为数字")
            pass
        else:
            ttPage=int(self.label_tPage.text())
            jump_gg = int(jump_g)
            if jump_gg > ttPage :
                QMessageBox.critical(self,"注意","输入错误，输入的数字超过最大页码了啊！")
            else:
                self.pageDisplay(jump_gg)


class MyForm ( QWidget, Ui_Form ):
    def __init__(self):
        super().__init__()
        self.setupUi(self)
        self.pushButton_jump.clicked.connect(self.jumpTo)



if __name__=='__main__':
#    global g #全局变量p——当前页面
    g=1
#    dblen=dblen() #获取数据库的总长度，赋值给变量dblen，这样就不需要每次去获取了
    app=QApplication(sys.argv)
    w = MyForm()
    w.pageDisplay(1)
    w.show()

#    a = NextOffice.tt.add.MyForm()
#    e = NextOffice.tt.edit.MyForm()
#   w.pushButton_edit01.clicked.connect(e.handle_click1)
#   w.pushButton_edit02.clicked.connect(e.handle_click2)
#  w.pushButton_edit03.clicked.connect(e.handle_click3)
#  w.pushButton_edit04.clicked.connect(e.handle_click4)
# w.pushButton_edit05.clicked.connect(e.handle_click5)

#    w.pushButton_new.clicked.connect(a.handle_click)
    app.exec_()



"""
UIC之后，将以下2个语句中的Main修改为self即可
self.pushButton_next.clicked.connect(self.reloadWidgetAdd)
self.pushButton_previous.clicked.connect(self.reloadWidgetDec)

"""